import Vue from 'vue'
import Vant from 'vant';
import 'amfe-flexible/index.js' // rem h5 适配
import 'vant/lib/index.css';
import '@/init/main.scss';
import '@/init/init.scss';
import '@/init/theme.scss'
import App from '@/App.vue'
import Api from '@/api/index'
import Utils from '@/utils/utils'
import Common from '@/utils/common'
import router from '@/router'
import store from '@/store'
import {
  formatDate,
  formatPrice,
  format
} from '@/utils/format'
import VueResource from 'vue-resource';
import '@/registerServiceWorker'

Vue.config.productionTip = false;

Vue.filter('formatDate', formatDate);
Vue.filter('formatPrice', formatPrice);
Vue.filter('format', format);
Vue.prototype.$api = Api;
Vue.prototype.$utils = Utils;
Vue.prototype.$common = Common;

Vue.use(Vant);
Vue.use(VueResource)


new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
